package com.ruoyi.quartz.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.ruoyi.common.core.text.Convert;
import com.ruoyi.quartz.domain.SysJobLog;
import com.ruoyi.quartz.mapper.SysJobLogMapper;
import com.ruoyi.quartz.service.ISysJobLogService;

/**
 * job日志信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-05-02
 */
@Service
public class SysJobLogServiceImpl implements ISysJobLogService 
{
    @Autowired
    private SysJobLogMapper sysJobLogMapper;

    /**
     * 查询job日志信息
     * 
     * @param id job日志信息主键
     * @return job日志信息
     */
    @Override
    public SysJobLog selectSysJobLogById(Long id)
    {
        return sysJobLogMapper.selectSysJobLogById(id);
    }

    /**
     * 查询job日志信息列表
     * 
     * @param sysJobLog job日志信息
     * @return job日志信息
     */
    @Override
    public List<SysJobLog> selectSysJobLogList(SysJobLog sysJobLog)
    {
        return sysJobLogMapper.selectSysJobLogList(sysJobLog);
    }

    /**
     * 新增job日志信息
     * 
     * @param sysJobLog job日志信息
     * @return 结果
     */
    @Override
    public int insertSysJobLog(SysJobLog sysJobLog)
    {
        return sysJobLogMapper.insertSysJobLog(sysJobLog);
    }

    /**
     * 修改job日志信息
     * 
     * @param sysJobLog job日志信息
     * @return 结果
     */
    @Override
    public int updateSysJobLog(SysJobLog sysJobLog)
    {
        return sysJobLogMapper.updateSysJobLog(sysJobLog);
    }

    /**
     * 批量删除job日志信息
     * 
     * @param ids 需要删除的job日志信息主键
     * @return 结果
     */
    @Override
    public int deleteSysJobLogByIds(String ids)
    {
        return sysJobLogMapper.deleteSysJobLogByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除job日志信息信息
     * 
     * @param id job日志信息主键
     * @return 结果
     */
    @Override
    public int deleteSysJobLogById(Long id)
    {
        return sysJobLogMapper.deleteSysJobLogById(id);
    }

	@Override
	public void cleanJobLog() {
		sysJobLogMapper.cleanJobLog();
	}
}
